package com.theaf.core.utils;

import org.dozer.spring.DozerBeanMapperFactoryBean;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.core.io.ClassPathResource;
import org.springframework.core.io.Resource;


import java.util.ArrayList;
import java.util.List;

import static com.sun.tools.internal.xjc.reader.Ring.add;

/**
 * @Author:songwenke
 * @Description:dozer配置
 * @Date:create in 14:13 2017/12/28
 * @Modified By:
 **/
@Configuration
public class DozerConfig {

    @Bean
    public DozerBeanMapperFactoryBean mapper() {
        DozerBeanMapperFactoryBean dozerBeanMapperFactoryBean = new DozerBeanMapperFactoryBean();
        //dozerBeanMapperFactoryBean.setMappingFiles(new Resource[]{new ClassPathResource("dozer-mapping.xml")});
        return dozerBeanMapperFactoryBean;
    }
}
